#ifndef RECORD_HPP
#define RECORD_HPP
#include <QVector>

enum RECORD_TYPE {
    //某时刻的温度场
    RECORD_TEMP_AT_TIME,
    //某点的温度变化曲线
    RECORD_TEMP_AT_POINT,
    //某时刻某点的温度值
    RECORD_TEMP_AT_POINT_AND_TIME
};


class Record {
public:
    int i;
    int j;
    int step;
    bool calculated;
    QVector<double> data;
    RECORD_TYPE type;
    bool operator==(const Record &b){
        if (b.type!=type){
            return false;
        }
        switch (b.type) {
            case RECORD_TEMP_AT_TIME:
                return step == b.step;
                break;
            case RECORD_TEMP_AT_POINT:
                return i == b.i && j == b.j;
                break;
            case RECORD_TEMP_AT_POINT_AND_TIME:
                return step == b.step && i == b.i && j == b.j;
                break;
        }
    }
};

#endif // RECORD_HPP
